Recording device and information processing device

ABSTRACT

A recording device includes a plurality of storage modules and a recording controller. With respect to a writing request, the recording controller generates parity data and writes data in the respective plurality of modules by dividing the data. When an error is detected with respect to a reading request, data of the error is restored from data and the parity data read from other recording modules. With respect to an initialization request of the storage module, the storage module to be initialized is specified from the plurality of storage modules, and an address conversion table is initialized. Moreover, identification information for identifying the initialized storage module is held. With respect to a request for cancelling the table initialization request of the storage module, reading of data from the storage module corresponding to the held identification information is processed as an error.

BACKGROUND

1. Technical Field

The present disclosure relates to a recording device and an informationprocessing device using the same.

2. Description of the Related Art

Unexamined Japanese Patent Publication No. 2012-141944 has disclosed arecording device incorporating a flash memory.

There has been desired a method in which using a trim that initializes amanagement table to thereby put all data into an unused state, a wholerecording medium is returned to an initialized state to increase awriting speed and perform smoothing.

SUMMARY

The present disclosure provides a recording device and an informationprocessing device that enable valuable data to be restored even if arequest for executing an erroneous trim is made.

A recording device in the present disclosure includes a plurality ofstorage modules, a recording controller that controls the plurality ofstorage module, and a management information storage that holdsidentification information for identifying each of the plurality ofstorage modules.

Each of the storage modules includes flash memories and a flash memorycontroller. Each of the flash memories has table storage areas thatholds data of an address conversion table, and a user data storage areathat holds data of a user. The flash memory controller performs readingand writing of the data of the flash memories, and initializes theaddress conversion table.

The recording controller has a parity generator, an error detector, adata restorer, and an initialization controller. The initializationcontroller has an address conversion table initializer and a storagemodule selector.

With respect to a writing request of data, the parity generatorgenerates parity data corresponding to writing data, and writes thegenerated parity data in any of the plurality of storage modules.

The error detector detects an error of data read from each of theplurality of storage modules as reading objects with respect to areading request of the data.

The data restorer restores the data of the storage module with the errordetected, using the data and the parity data read from the storagemodule other than the storage module with the error detected, when theerror detector detects the error.

With respect to an initialization request to the storage module, theinitialization controller specifies the storage module as aninitialization object, based on the identification information held bythe management information storage. The initialization controller theninstructs the flash memory controller to initialize the addressconversion table of the specified storage module as the initializationobject. Furthermore, the initialization controller stores theidentification information for identifying the storage module as theinitialization object in the management information storage.

Moreover, with respect to a request for cancelling the initializationrequest of the storage module, the initialization controller instructsthe error detector to process, as an error, data read from the storagemodule as the initialization object corresponding to the identificationinformation held by the management information storage.

According to the present disclosure, there can be provided a recordingdevice that enables original data to be restored even if initializationprocessing of an address conversion table is executed by a request of anerroneous trim.

BRIEF DESCRIPTION OF DRAWINGS

FIG. 1 is a block diagram showing a whole configuration of aninformation processing device in a first exemplary embodiment;

FIG. 2 is a block diagram showing a configuration of a recording devicein the first exemplary embodiment;

FIG. 3 is a block diagram showing a configuration of a storage module inthe first exemplary embodiment;

FIG. 4 is a diagram showing an outline of a structure of an addressconversion table in the first exemplary embodiment;

FIG. 5 is an outline of the structure of the address conversion tableafter initialization in the first exemplary embodiment;

FIG. 6 is a sequence diagram showing operation of the informationprocessing device in the first exemplary embodiment;

FIG. 7 is a diagram for describing a data recording method forperforming data restoration processing using parity data in the firstexemplary embodiment; and

FIG. 8 is a diagram for describing processing at the time of datarestoration in the first exemplary embodiment.

DETAILED DESCRIPTION

Hereinafter, referring to the drawings as needed, exemplary embodimentswill be described in detail. However, unnecessarily detailed descriptionmay be omitted. For example, detailed description of a well-known itemor redundant description of substantially the same configuration may beomitted. This is to avoid unnecessary redundancy of the followingdescription and to facilitate understanding of those in the art.

The accompanying drawings and the following description are provided forthose in the art to sufficiently understand the present disclosure, andare not intended to limit the subject of the claims.

First Exemplary Embodiment

Hereinafter, a first exemplary embodiment will be described withreference to FIGS. 1 to 8.

[1-1. Configuration] [1-1-1. Whole Configuration of InformationProcessing Device]

FIG. 1 is a block diagram showing a whole configuration of aninformation processing device in the first exemplary embodiment. Theinformation processing device is configured by host device 200 andrecording device 100. Host device 200 has CPU(Central Processing Unit)210, display 220, and host device I/F (Interface) 230. CPU 210 controlswhole host device 200. Display 220 is a display device such as a liquidcrystal display and the like. Host device I/F 230 is an interface forhost device 200 to access recording device 100. Host device 200 mayaccess recording device 100 through an adaptor that performs protocolconversion or the like.

[1-1-2. Configuration of Recording Device]

FIG. 2 is a block diagram showing a configuration of recording device100 in the first exemplary embodiment. Recording device 100 has host I/F110, recording controller 120, management information storage 130,device buffer 135, storage module I/F 140, and a plurality of storagemodules 150 (150A to 150E). While in the first exemplary embodiment, aform in which recording device 100 has five storage modules 150A to 150Ewill be described, a number of storage modules 150 is not limited tofive, and only needs to be plural.

Host I/F 110 is connected to host device 200 by host device I/F 230 toperform transmission/reception of commands between host device 200 andrecording device 100. Recording controller 120 controls whole recordingdevice 100. Recording controller 120 may be configured only by hardware,or may be implemented by combining hardware and software. Recordingcontroller 120 may be implemented by a microcomputer or the like.Management information storage 130 includes a memory. Managementinformation storage 130 holds information for identifying initializedstorage module 150 in the memory. Device buffer 135 temporarily holdsdata to be transmitted/received between host device 200 and storagemodule 150. Storage module I/F 140 is an interface to issue commands forinitialization, reading of data, and writing of the data to storagemodule 150.

Recording controller 120 has parity generator 121, error detector 122,data restorer 123, and initialization controller 124. Initializationcontroller 124 has address conversion table initializer 125 and storagemodule selector 126.

Parity generator 121 generates parity data for restoring the data to bewritten in storage modules 150 to write the same in device buffer 135.Furthermore, parity generator 121 instructs writing of the parity datawritten in device buffer 135 to storage modules 150A to 150E via storagemodule I/F 140 is an error.

Error detector 122 determines whether or not the data read from storagemodule 150 via storage module I/F 140 is an error. Determination as towhether or not the data is an error may be made, using an errorcorrection code (ECC). For example, when the data is written in thestorage modules 150, the error correction code is given on a basis ofsector. When the data is read from storage module 150, whether or notthe read data is an error is determined, using this error correctioncode.

Data restorer 123 restores the data determined to be an error by errordetector 122 into normal data, using data of storage modules 150 otherthan storage module 150 where the error data is stored. Restorationprocessing of the data will be described in detail later.

Address conversion table initializer 125 instructs initialization ofaddress conversion table 158 to storage module 150 via storage moduleI/F 140.

Storage module selector 126 selects storage module 150 to beinitialized. Storage module selector 126 manages management informationstorage 130 and uses the same to hold necessary information.

Storage modules 150A to 150E may have a common configuration. Storagemodule 150 in the case of the common configuration is shown in FIG. 3.Storage module 150 has module I/F 151, flash memory controller 152,buffer 154, flash memory I/F 155, and flash memories 156.

Module I/F 151 receives a command from recording controller 120 andpasses the command to flash memory controller 152. Moreover, module I/F151 performs data transfer between recording controller 120 and buffer154.

Flash memory controller 152 controls whole storage module 150. Flashmemory controller 152 can be implemented by hardware, a microcomputer orthe like. Buffer 154 temporarily holds data to be passed betweenrecording controller 120 and flash memories 156. Flash memory I/F 155executes initialization processing, and issues a reading request and awriting request to flash memories 156.

Flash memory controller 152 has table initializer 153. Table initializer153 specifies an address where latest valid address conversion table 158exists, and initializes relevant address conversion table 158.

When receiving the command for reading from recording controller 120,flash memory controller 152 reads address conversion table 158 in tablestorage areas 157 to find an address where data of a user (user data)exists. Thereafter, flash memory controller 152 reads the user data inuser data storage area 159, based on the found address.

When receiving the command for writing from recording controller 120,flash memory controller 152 reads address conversion table 158 tospecify an area where the user data is to be written. Flash memorycontroller 152 writes the user data in the specified area, and updatesaddress conversion table 158.

Each of the flash memories 156 has table storage areas 157 and user datastorage area 159. Each of the table storage areas 157 is an area wheredata of address conversion table 158 is stored, and holds managementdata for converting a logical address and a physical address. User datastorage area 159 is an area where the data of the user (the user data)that the user reads and writes is stored. Flash memory controller 152performs processing of the reading and the writing of the data to flashmemories 156, processing of the initialization to address conversiontable 158, and the like through flash memory I/F 155.

[1-1-3. Data Configuration at the Time of Initialization of TableStorage Areas]

FIG. 4 is information held as the data in address conversion table 158.Here, as one example, one of the table storage areas 157 includes tablepointer table 400 and three blocks 420 to 440 to configure addressconversion table 158. Address conversion table 158 is logically dividedinto four update unit tables a to d. Furthermore, each of the updateunit tables has a plurality of entries. Each of the entries hasmanagement data for converting between a logical address and a physicaladdress. As illustrated, contents of update unit tables a to d are held,using block 420 and block 430 of blocks 420 to 440. The contents ofseven update unit tables of the stored contents of table storage areas157 are invalid. Valid update unit table a and valid update unit table dare stored in block 430. Moreover, valid update unit table b and validupdate unit table c are stored in block 420. Storage locations of thevalid contents relating to update unit tables a to d can be specified bypointers 402 held in table pointer table 400. In the example of FIG. 4,each of pointers 402 held in table pointer table 400 is associated witha logical address, and searching is performed by using at least part ofthe logical address as index 401. This index 401 may be configured by acommon high-order bit to each of the logical addresses included in theentries each configuring the update unit table, and be registered intable pointer table 400. The valid tables in blocks 420 to 440 can bedetected, for example, by sequentially searching for the valid entriesfrom heads of the blocks.

Next, update of the information in the table initialization processingwill be described. FIG. 5 shows the information held in addressconversion table 158 after the table initialization processing isperformed. In order to initialize only pointers 402 of table pointertable 400, table pointer table 400 is generated in a new area in tablestorage areas 157. This allows the contents of pointers 402 to be reset,so that all the past writing can be invalidated for new writing. Thisprocessing can be performed at a high speed because the writing in onlytable pointer table 400 suffices.

[1-2. Operation] [1-2-1. Sequence Between Host Device and RecordingDevice]

FIG. 6 shows a sequence of operation between host device 200 andrecording device 100.

Host device 200 issues a Read/Write request to recording device 100 atthe time of normal reading or writing (S101). Namely, the Read requestis issued at the time of reading, and the Write request is issued at thetime of writing. Recording device 100, which has received the Read/Writerequest, performs the reading or writing to storage modules 150 inresponse to the request, and notifies host device 200 of the completion(S102). At the time of reading, recording device 100 returns the dataread from storage module 150 to host device 200 together with thenotification of the completion. At the time of writing, the writing dataand the parity data generated in parity generator 121 are written ineach of storage modules 150. Furthermore, at the time of writing,address conversion table 158 in flash memories 156 is updated inaccordance with the writing content in the user data storage area at thetime of writing.

Next, a case where host device 200 issues a table initialization requestto recording device 100 will be described (S103). Upon receiving thetable initialization request from host device 200, storage moduleselector 126 selects storage module 150 to be subjected to tableinitialization from storage modules 150A to 150E. Storage moduleselector 126 acquires identification information of storage module 150initialized the last time from management information storage 130,selects storage module 150 other than storage module 150 initialized thelast time as storage module 150 to be subjected to the tableinitialization. Address conversion table initializer 125 issues aninitialization request to selected storage module 150. In storage module150 that has received the initialization request, table initializer 153executes the table initialization processing (S104). Initializationcontroller 124 causes management information storage 130 to store theidentification information for identifying initialized storage module150, and to notify host device 200 of the completion of the moduleinitialization (S105). Thereafter, host device 200 performs the normalreading and writing processing as needed (S106).

Next, a case where host device 200 issues an erroneous tableinitialization request will be described (S107). Recording device 100performs the processing equivalent to above-described processing S104for the address conversion table initialization and moduleidentification information update S105 (S108, S109). In order to restoredata lost in this erroneous address conversion table initialization,host device 200 issues, to recording device 100, an address conversiontable initialization invalidation request, that is, a request forcancelling the request for initialization of address conversion table158 (S110). When recording device 100 receives the request,initialization controller 124 reads the identification information foridentifying initialized storage module 150 from management informationstorage 130. Furthermore, in order to restore the data of storage module150 to be read, initialization controller 124 instructs error detector122 so that address conversion table 158 treats the data of initializedstorage module 150 as an error. Initialization controller 124 thennotifies host device 200 of the completion of the table initializationinvalidation (S111). Thereafter, host device 200 issues the Read requestfor performing the normal reading to recording device 100 (S112).Recording device 100, which has received the Read request, causes theerror detector 122 to determine, as an error, the reading of the datafrom storage module 150 whose address conversion table 158 has beenerroneously initialized. Based on this determination, data restorer 123restores normal data, using the data and the parity data of storagemodules 150 other than storage module 150 erroneously initialized. Therestored data is transmitted to host device 200 (S113).

[1-2-2. Data Restoration Processing]

FIG. 7 is a diagram for describing data recording method for performingdata restoration processing, using the parity data. This operation is atechnique of enhancing reliability of hard disk, based on a method ofRAID (Redundant Arrays of Inexpensive Disks). Here, combining aplurality of pieces of hard disk allows operation as a virtual one pieceof hard disk, and a redundant configuration enhances reliability.

Recording device 100 generates the parity data for data restoration inparity generator 121 with respect to a writing request from host device200. Furthermore, the generated parity data and the writing data fromhost device 200 are written in storage modules 150A to 150E in an equalsize. Recording device 100, for example, performs the writing in asector (512 bytes) unit, in a page size (4K bytes) unit of the flashmemories. As one example, as shown in FIG. 7, recording device 100divides the writing data from host device 200 into four to write thedivided data in respective storage modules 150A to 150D. Additionally,the parity data is generated from the divided four pieces of data, andis written in one remaining storage module 150E. In order to enhance thereliability, recording device 100 sequentially changes storage module150 in which the parity data is written in this writing processing. Evenif one piece of data of five storage modules 150 including the paritydata becomes an error, the data, which has become the error, can berestored from the other four storage modules 150.

FIG. 8 is a diagram for describing a case where the restoration isperformed from the erroneous address conversion table initialization.FIG. 8 shows an example when address conversion table 158 of storagemodule 150C is erroneously initialized. In this case, based on theinstruction from initialization controller 124, error detector 122 issure to determine the data read from storage module 150C as an errorwith respect to the reading request to storage module 150C. Errordetector 122 notifies data restorer 123 that the reading from storagemodule 150C has been the error. Data restorer 123 restores the data ofstorage module 150C by the data and the parity data read from storagemodules 150 other than storage module 150C.

[1-3. Effects]

As described above, in the first exemplary embodiment, recording device100 includes the plurality of storage modules 150, recording controller120 that controls the plurality of storage modules 150, and managementinformation storage 130 that holds the identification information foridentifying each of the plurality of storage modules 150.

Storage modules 150 each include flash memories 156 and flash memorycontroller 152. Each of the flash memories 156 has table storage areas157 that holds the data of address conversion table 158, and user datastorage area 159 that holds the user data. Flash memory controller 152performs the reading and the writing of the data of flash memories 156,and initializes address conversion table 158.

Recording controller 120 has parity generator 121, error detector 122,data restorer 123, and initialization controller 124. Initializationcontroller 124 has address conversion table initializer 125 and storagemodule selector 126.

Parity generator 121 generates the parity data corresponding to thewriting data with respect to the writing request of the data, and writesthe generated parity data in any of the plurality of storage modules150.

Error detector 122 detects an error of the data read from each of theplurality of storage modules 150 as the reading objects with respect tothe reading request of the data.

When the error detector 122 detects an error, data restorer 123 restoresthe data of storage module 150 with the error detected, using the dataand the parity data read from storage modules 150 other than storagemodule 150 with the error detected.

Initialization controller 124 specifies storage module 150 as theinitialization object, based on the identification information held bymanagement information storage 130 with respect to the initializationrequest to storage module 150. Initialization controller 124 instructsflash memory controller 152 to initialize address conversion table 158of specified storage module 150 as the initialization object.Furthermore, initialization controller 124 stores the identificationinformation for identifying storage module 150 as the initializationobject in management information storage 130.

Moreover, initialization controller 124 instructs error detector 122 toprocess, as an error, the data read from storage module 150 as theinitialization object corresponding to the identification informationheld by management information storage 130 with respect to the requestfor cancelling the initialization request of storage module 150.

This enables the original data to be restored even if the initializationprocessing of address conversion table 158 is executed by an erroneoustrim request.

Other Exemplary Embodiments

As described above, the first exemplary embodiment has been described asillustration of the technique disclosed in the present disclosure.However, the technique in the present disclosure is not limited thereto,but can also be applied to exemplary embodiments in which modifications,replacements, additions, omissions or the like are made. Moreover, therespective components described in the first exemplary embodiment can becombined into a new exemplary embodiment.

Hereinafter, other exemplary embodiments will be described.

While in the first exemplary embodiment, the case where five storagemodules 150 are used has been described, a number of storage modules 150is not limited thereto, and only needs to be plural. Moreover, while inthe first exemplary embodiment, the case where one piece of parity datais generated has been described, a number of pieces of parity data isnot limited thereto, but a plurality of pieces of parity data may begenerated. Moreover, while in the first exemplary embodiment, the casewhere the four pieces of data and the one piece of parity data arerecorded on five different storage modules 150 has been described, thecombination of the number of pieces of the data and the number of piecesof the parity data is not limited thereto, but another combination maybe employed.

While in the first exemplary embodiment, the example in which thedetermination of the error of initialized storage module 150 isperformed in error detector 122 has been described, the errordetermination can be implemented by a configuration in which storagemodule 150 returns error data. For example, the error determination canalso be implemented by processing an error correction code given to dataso that this data is detected as an error.

In the case where at the time of initialization of address conversiontable 158, not only the initialization of address conversion table 158but physical erasure of storage module 150 is performed, recordingdevice 100 can attain an increase in speed at the time of writing inaddition to equivalent effects.

Moreover, recording device 100 can also exert the effects by designatingan area of address conversion table 158 to be initialized as a parameterto correspond to only the predetermined area. Specifically, for example,host device 200 issues to recording device 100 an initialization requestin which the area of storage module 150 to be initialized is designatedby the parameter. Initialization controller 124 specifies storage module150 as the initialization object, and instructs flash memory controller152 to initialize the predetermined area in address conversion table 158of specified storage module 150 as the initialization object. Flashmemory controller 152, which has received the instruction, initializesaddress conversion table 158, and stores the identification informationfor identifying initialized storage module 150 and information of theinitialized area. Furthermore, with respect to a request for cancellingthe table initialization request of storage module 150, flash memorycontroller 152 of specified storage module 150 acquires theidentification information and the information of the initialized areaof the storage module 150 initialized the last time. An error correctioncode of this data is processed so that the reading of the data from theinitialized area of storage module 150 corresponding to the acquiredidentification information of storage module 150 is determined as anerror.

While in the first exemplary embodiment, storage module selector 126acquires the identification information of storage module 150initialized the last time from management information storage 130 toselect storage module 150 other than storage module 150 initialized thelast time as table initialization object. However, a method forselecting storage module 150 to be initialized is not limited thereto,but another method may be employed. The identification information ofstorage module 150 initialized the last time may be held, and storagemodule 150 having a smallest number of times of initialization may beselected as the initialization object. This can bring about leveling ofthe writing in the flash memories.

Moreover, host device 200 may be sure to execute the initialization ofaddress conversion table 158 when storage module 150 is formatted.

Alternately, host device 200 may provide a user interface on display220, so that the initialization of address conversion table 158 ofrecording device 100 is executed expressly by the user, or theinitialization of address conversion table 158 may be performed when theinformation processing device is given over to the next user after theuse of the information processing device has been completed.

The present disclosure can be applied to electronic equipment thatrecords a video on a recording device. Specifically, the presentdisclosure can be applied to a camera recorder for business use, adigital still camera, a movie, a versatile personal computer and thelike.

What is claimed is:
 1. A recording device comprising: a plurality ofstorage modules; a recording controller that controls the plurality ofstorage modules; and a management information storage that holdsidentification information for identifying each of the plurality ofstorage modules, wherein each of the storage modules includes: a flashmemory having a table storage area that holds data of an addressconversion table, and a user data storage area that holds data of auser; and a flash memory controller that performs reading and writing ofthe data of the flash memory, and initializes the address conversiontable, and the recording controller includes: a parity generator thatgenerates parity data corresponding to writing data with respect to awriting request of the data, and writes the generated parity data in anyof the plurality of storage modules; an error detector that detects anerror of data read from each of the plurality of storage modules withrespect to a reading request of the data; a data restorer that restoresthe data of one of the plurality of storage modules with the errordetected, using the data and the parity data read from some of theplurality of storage modules other than the storage module with theerror detected, when the error detector detects the error; and aninitialization controller, with respect to an initialization request,the initialization controller specifying one of the plurality of storagemodules as an initialization object, based on the identificationinformation held by the management information storage, instructing theflash memory controller to initialize the address conversion table ofthe specified storage module as the initialization object, and storingthe identification information for identifying the storage module as theinitialization object in the management information storage, and withrespect to a request for cancelling the initialization request, theinitialization controller instructing the error detector to process, asan error, data read from the storage module as the initialization objectcorresponding to the identification information held by the managementinformation storage.
 2. The recording device according to claim1,wherein with respect to the initialization request, the initializationcontroller specifies one of the plurality of storage modules to beinitialized next, based on the identification information of one of theplurality of storage modules initialized the last time, theidentification information being held by the management informationstorage.
 3. The recording device according to claim 1, wherein in thestorage module as the initialization object, the flash memory controllerinitializes the address conversion table, and physically erases the datain the flash memory.
 4. The recording device according to claim 1,wherein the initialization controller specifies the storage module asthe initialization object from the plurality of storage modules when theinitialization request is an initialization request in which an area tobe initialized is designated, the flash memory controller of thespecified storage module initializes the address conversion table, andstores identification information of the initialized storage module andinformation of the initialized area with respect to the initializationrequest, and acquires the identification information and the informationof the initialized area stored in the flash memory controller of thespecified storage module, and processes, as an error, reading of thedata from the initialized area of the storage module corresponding tothe acquired identification information with respect to the request forcancelling the initialization request.
 5. An information processingdevice comprising: the recording device according to claim 1; and a hostdevice that issues the writing request of the data, the reading requestof the data, the initialization request, and the request for cancellingthe initialization request to the recording device.
 6. The informationprocessing device according to claim 5, wherein the host device has auser interface, and issues the initialization request of the storagemodule to the recording device by an instruction from a user.